package com.ly.mpayment.persist.entity.ele;


import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

import com.ly.mpayment.persist.entity.UpOrder;



/**
 * EleRecord entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name="ele_record"

)

public class EleRecord  implements java.io.Serializable {


    // Fields

     private String recordId;
     private ElectronicAccount electronicAccount;
     private UpOrder upOrder;
     private String phoneNum;
     private Integer rechargeState;
     private Date startTime;
     private Date endTime;
     private BigDecimal amount;
     private String chargeDetail;
     private String flow;
     private int callBack;
     private String city;
//     private String remark;

    // Constructors

    /** default constructor */
    public EleRecord() {
    }

	/** minimal constructor */
    public EleRecord(String recordId) {
        this.recordId = recordId;
    }

    /** full constructor */
    public EleRecord(String recordId, ElectronicAccount electronicAccount, UpOrder upOrder, String phoneNum, Integer rechargeState, Date startTime, Date endTime, BigDecimal amount, String chargeDetail, String flow) {
        this.recordId = recordId;
        this.electronicAccount = electronicAccount;
        this.upOrder = upOrder;
        this.phoneNum = phoneNum;
        this.rechargeState = rechargeState;
        this.startTime = startTime;
        this.endTime = endTime;
        this.amount = amount;
        this.chargeDetail = chargeDetail;
        this.flow = flow;
    }


    // Property accessors
    @Id
    @GeneratedValue(generator = "uuid")
    @GenericGenerator(name = "uuid", strategy = "uuid")
    @Column(name="record_id", unique=true, nullable=false, length=36)
    public String getRecordId() {
        return this.recordId;
    }

    public void setRecordId(String recordId) {
        this.recordId = recordId;
    }
	@ManyToOne(fetch=FetchType.LAZY)
        @JoinColumn(name="acc_id")

    public ElectronicAccount getElectronicAccount() {
        return this.electronicAccount;
    }

    public void setElectronicAccount(ElectronicAccount electronicAccount) {
        this.electronicAccount = electronicAccount;
    }
	@ManyToOne(fetch=FetchType.LAZY)
        @JoinColumn(name="uporderuuid")
	 public UpOrder getUpOrder() {
		return upOrder;
	}

	public void setUpOrder(UpOrder upOrder) {
		this.upOrder = upOrder;
	}

    @Column(name="phone_num", length=15)

    public String getPhoneNum() {
        return this.phoneNum;
    }

	public void setPhoneNum(String phoneNum) {
        this.phoneNum = phoneNum;
    }

    @Column(name="recharge_state")
    public int getRechargeState() {
        return this.rechargeState;
    }

    public void setRechargeState(Integer rechargeState) {
        this.rechargeState = rechargeState;
    }

    @Column(name="start_time", length=19)

    public Date getStartTime() {
        return this.startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    @Column(name="end_time", length=19)

    public Date getEndTime() {
        return this.endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    @Column(name="amount", precision=10, scale=0)

    public BigDecimal getAmount() {
        return this.amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    @Column(name="charge_detail", length=15)

    public String getChargeDetail() {
        return this.chargeDetail;
    }

    public void setChargeDetail(String chargeDetail) {
        this.chargeDetail = chargeDetail;
    }

    @Column(name="flow", length=36)

    public String getFlow() {
        return this.flow;
    }

    public void setFlow(String flow) {
        this.flow = flow;
    }

    @Column(name="call_back")
    public int getCallBack() {
		return callBack;
	}

	public void setCallBack(int callBack) {
		this.callBack = callBack;
	}

	@Column(name="city")
	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}



//	@Column(name="remark")
//	public String getRemark() {
//		return remark;
//	}
//
//	public void setRemark(String remark) {
//		this.remark = remark;
//	}


}
